{include file="Public:header" /}
{include file="Public:nav" /}		

		<div class="page page-current" id="order">
			<div class="bar bar-nav">
				<h1 class="title">预约管理</h1>
				<i class="icon icon-left" onclick="window.history.go(-1);"></i>
			</div>
			
			<div class="content">
			<div class="buttons-tab fixed-tab" data-offset="34" style="margin-top:10px;">
				<a class="tab-link button active" href="#order_1">全部预约</a>
				<a class="tab-link button" href="#order_4">已发布</a>
				<a class="tab-link button" href="#order_2">待审核</a>
				<a class="tab-link button" href="#order_3">不通过</a>
			</div>
			<div class="tabs">
				<div class="tab active" id="order_1">
				<div id="all_activity">
                                    {foreach name="all_make" item="all" key="r"}
					 <div class="card user_order_card">
                                             <div class="card-header"><span>星期&nbsp;&nbsp;{$all['select_time']}</span>
					  <a>{switch name="all['trial_status']"}
						    {case value="1"}待审核{/case}
						    {case value="2"}已通过{/case}
						    {default /}不通过
						 {/switch}</a>
					  </div>
                                             
					  <div class="card-content">
					  <a {if condition="$all['trial_status'] neq 2"} 
					  	 href="{:U('Users/user_expert_yuyue',array('id'=>$all['id']))}"
					  	 {else/} 
					  	 href="{:U('Apply/expert_page',array('id'=>$all['apply_id']['id']))}"
					  	 {/if} >
					    <div class="list-block media-list">
					      <ul>
					        <li class="item-content">
					          <div class="item-media">
					            <img src="{$all['head_img']}" style="width:100px;" />
					          </div>
					          <div class="item-inner">
					            <div class="item-title-row">
					              <div class="item-title">{$all['name']}&nbsp;&nbsp;{$all['mobile']}</div>
					            </div>
					            <p style="font-size:12px;" class="color-gray">{$all['add_time']|date="Y-m-d",###}</p>
                                                    <p style="font-size:12px;" class="color-gray">{$all['yuyue_count']}人已预约</p>
					          </div>
					        </li>
					      </ul>
					    </div>
					    </a>
					  </div>
					  <div class="card-footer">
<!--                                              {if condition="$all['status'] eq 1"}
                                            <a style="display: inline-block;" href="#" class="button button-fill" >暂停预约</a>
                                            {else/}
                                            <a style="display: inline-block;" href="#" class="button button-fill" >开启预约</a>
                                            {/if}-->
                                             {if condition="$all['trial_status'] neq 2"} 
                                             <a style="display: inline-block;" href="{:U('Users/user_expert_yuyue',array('id'=>$all['id']))}" class="button button-fill" >修改</a></div>
                                             {else/}
                                             <a style="display: inline-block;" href="{:U('Apply/view_discuss',array('id'=>$all['id']))}" class="button button-fill" >查看预约</a> 
                                             <a style="display: inline-block;" href="{:U('Apply/expert_page',array('id'=>$all['apply_id']['id']))}" class="button button-fill" >查看详情</a></div>
                                             {/if}
					</div>
                                    {/foreach}
				</div>
					{if condition="$all_show"}
					<div class="infinite-scroll-preloader" id="all_quan" style="display:none;">
						<div class="preloader"></div>
					 </div>
					<p onclick="ajax_sourch_submit();" class="all_more" id="load_more"><span class="icon icon-down"></span> 点击加载更多...</p>
					{else/}
					<p id="load_more"> 暂无数据！</p>
					{/if}
				</div>
				
				
				<div class="tab" id="order_4">
				<div id="release_activity">
				  {foreach name="release_make" item="release" key="r"}
                                <div class="card user_order_card">
                                    <div class="card-header"><span>星期&nbsp;&nbsp;{$release['select_time']}</span>
                                        <a>{switch name="release['trial_status']"}
                                            {case value="1"}待审核{/case}
                                            {case value="2"}已通过{/case}
                                            {default /}不通过
                                            {/switch}</a>
                                    </div>

                                    <div class="card-content">
                                        <a {if condition="$release['trial_status'] neq 2"} 
                                            href="{:U('Users/user_expert_yuyue',array('id'=>$release['id']))}"
                                            {else/} 
                                            href="{:U('Apply/expert_page',array('id'=>$release['apply_id']['id']))}"
                                            {/if} >
                                            <div class="list-block media-list">
                                                <ul>
                                                    <li class="item-content">
					          <div class="item-media">
					            <img src="{$release['head_img']}" style="width:100px;" />
					          </div>
					          <div class="item-inner">
					            <div class="item-title-row">
					              <div class="item-title">{$release['name']}&nbsp;&nbsp;{$release['mobile']}</div>
					            </div>
					            <p style="font-size:12px;" class="color-gray">{$release['add_time']|date="Y-m-d",###}</p>
                                                    <p style="font-size:12px;" class="color-gray">{$release['yuyue_count']}人已预约</p>
					          </div>
					        </li>
                                                </ul>
                                            </div>
                                        </a>
                                    </div>
                                    <div class="card-footer">
                                        <!--<span>￥<font>{$all['price']}</font></span><span>-->
                                        {if condition="$release['trial_status'] neq 2"} 
                                        <a style="display: inline-block;" href="{:U('Users/user_expert_yuyue',array('id'=>$release['id']))}" class="button button-fill" >修改</a></div>
                                    {else/}
                                    <a style="display: inline-block;" href="{:U('Apply/view_discuss',array('id'=>$release['id']))}" class="button button-fill" >查看预约</a> 
                                    <a style="display: inline-block;" href="{:U('Apply/expert_page',array('id'=>$release['apply_id']['id']))}" class="button button-fill" >查看详情</a></div>
                                {/if}
                                </div>
                                {/foreach}
				</div>
					{if condition="$release_show"}
					<div class="infinite-scroll-preloader" id="release_quan" style="display:none;">
						<div class="preloader"></div>
					 </div>
					<p onclick="ajax_sourch_release_submit();" class="release_more" id="load_more"><span class="icon icon-down"></span> 点击加载更多...</p>
					{else/}
					<p id="load_more"> 暂无数据！</p>
					{/if}
				</div>
		
			
			<div class="tab" id="order_2">
			<div id="stay_activity">
					{foreach name="stay_make" item="stay" key="s"}
                        <div class="card user_order_card">
                            <div class="card-header"><span>星期&nbsp;&nbsp;{$stay['select_time']}</span>
                                <a>{switch name="stay['trial_status']"}
                                    {case value="1"}待审核{/case}
                                    {case value="2"}已通过{/case}
                                    {default /}不通过
                                    {/switch}</a>
                            </div>

                            <div class="card-content">
                                <a {if condition="$stay['trial_status'] neq 2"} 
                                    href="{:U('Users/user_expert_yuyue',array('id'=>$stay['id']))}"
                                    {else/} 
                                    href="{:U('Apply/expert_page',array('id'=>$stay['apply_id']['id']))}"
                                    {/if} >
                                    <div class="list-block media-list">
                                        <ul>
                                            <li class="item-content">
					          <div class="item-media">
					            <img src="{$stay['head_img']}" style="width:100px;" />
					          </div>
					          <div class="item-inner">
					            <div class="item-title-row">
					              <div class="item-title">{$stay['name']}&nbsp;&nbsp;{$stay['mobile']}</div>
					            </div>
					            <p style="font-size:12px;" class="color-gray">{$stay['add_time']|date="Y-m-d",###}</p>
                                                    <p style="font-size:12px;" class="color-gray">{$stay['yuyue_count']}人已预约</p>
					          </div>
					        </li>
                                        </ul>
                                    </div>
                                </a>
                            </div>
                            <div class="card-footer">
                                <!--<span>￥<font>{$all['price']}</font></span><span>-->
                                {if condition="$stay['trial_status'] neq 2"} 
                                <a style="display: inline-block;" href="{:U('Users/user_expert_yuyue',array('id'=>$stay['id']))}" class="button button-fill" >修改</a></div>
                            {else/}
                            <a style="display: inline-block;" href="{:U('Apply/view_discuss',array('id'=>$stay['id']))}" class="button button-fill" >查看预约</a> 
                            <a style="display: inline-block;" href="{:U('Apply/expert_page',array('id'=>$stay['apply_id']['id']))}" class="button button-fill" >查看详情</a></div>
                        {/if}
                        </div>
                        {/foreach}
			 </div>
			 		{if condition="$stay_show"}
					<div class="infinite-scroll-preloader" id="stay_quan" style="display:none;">
						<div class="preloader"></div>
					 </div>
					<p onclick="ajax_sourch_stay_submit();" class="stay_more" id="load_more"><span class="icon icon-down"></span> 点击加载更多...</p>
					{else/}
					<p id="load_more"> 暂无数据！</p>
					{/if}
			</div>
					
			
			
			<div class="tab" id="order_3">
				<div id="not_activity">
					{foreach name="not_make" item="not" key="n"}
                        <div class="card user_order_card">
                            <div class="card-header"><span>星期&nbsp;&nbsp;{$not['select_time']}</span>
                                <a>{switch name="not['trial_status']"}
                                    {case value="1"}待审核{/case}
                                    {case value="2"}已通过{/case}
                                    {default /}不通过
                                    {/switch}</a>
                            </div>

                            <div class="card-content">
                                <a {if condition="$not['trial_status'] neq 2"} 
                                    href="{:U('Users/user_expert_yuyue',array('id'=>$not['id']))}"
                                    {else/} 
                                    href="{:U('Apply/expert_page',array('id'=>$not['apply_id']['id']))}"
                                    {/if} >
                                    <div class="list-block media-list">
                                        <ul>
                                            <li class="item-content">
					          <div class="item-media">
					            <img src="{$not['head_img']}" style="width:100px;" />
					          </div>
					          <div class="item-inner">
					            <div class="item-title-row">
					              <div class="item-title">{$not['name']}&nbsp;&nbsp;{$not['mobile']}</div>
					            </div>
					            <p style="font-size:12px;" class="color-gray">{$not['add_time']|date="Y-m-d",###}</p>
                                                    <p style="font-size:12px;" class="color-gray">{$not['yuyue_count']}人已预约</p>
					          </div>
					        </li>
                                        </ul>
                                    </div>
                                </a>
                            </div>
                            <div class="card-footer">
                                <!--<span>￥<font>{$all['price']}</font></span><span>-->
                                {if condition="$not['trial_status'] neq 2"} 
                                <a style="display: inline-block;" href="{:U('Users/user_expert_yuyue',array('id'=>$not['id']))}" class="button button-fill" >修改</a></div>
                            {else/}
                            <a style="display: inline-block;" href="{:U('Apply/view_discuss',array('id'=>$not['id']))}" class="button button-fill" >查看预约</a> 
                            <a style="display: inline-block;" href="{:U('Apply/expert_page',array('id'=>$not['apply_id']['id']))}" class="button button-fill" >查看详情</a></div>
                        {/if}
                        </div>
                        {/foreach}
			 </div>
			 		{if condition="$not_show"}
					<div class="infinite-scroll-preloader" id="not_quan" style="display:none;">
						<div class="preloader"></div>
					 </div>
					<p onclick="ajax_sourch_not_submit();" class="not_more" id="load_more"><span class="icon icon-down"></span> 点击加载更多...</p>
					{else/}
					<p id="load_more"> 暂无数据！</p>
					{/if}
			</div>
			
			
			
			</div>
		</div>
		</div>
		<div class="page" id="order_page">
			<div class="bar bar-nav">
				<h1 class="title">订单详情</h1>
				<i class="icon icon-left" onclick="window.history.go(-1);"></i>
			</div>
			<nav class="bar bar-tab ticket-tab">
				<a class="tab-item" href="publish_1.html">
					<span class="icon iconfont icon-add"></span>
					<span class="tab-label">我要发布活动</span>
				</a>
				<a class="tab-item open-3-modal">
					<span class="icon icon-check"></span>
					<span class="tab-label">完成活动</span>
				</a>
			</nav>
			<div class="content">
				<div class="list-block ticket">
				    <ul>
				    	<li class="item-content">
					        <div class="item-inner">
					          <p class="item-title">免费票<span>￥0.00</span></p>
					        </div>
				      	</li>
				      	<li class="item-content">
					        <div class="item-inner text-center">
					        	<div class="item-title ticket_img">
					        		<h3>0005 4654 4561</h3>
					        		<img src="__PUBLIC__/Home/activity/img/img_01.jpg" >
					        		<p>待参与</p>
					        	</div>
					        </div>
				      	</li>
				        <li class="item-content">
					        <div class="item-inner">
					          <div class="item-title text-center" style="width:100%">活动名称活动名称活动名称活动名称活动名称</div>
					        </div>
				        </li>
				        <li class="item-content">
					        <div class="item-inner">
					          <div class="item-title">主办方:</div>
					          <div class="item-after">时虹时期中国</div>
					        </div>
				        </li>
				        <li class="item-content">
					        <div class="item-inner">
					          <div class="item-title">时　间:</div>
					          <div class="item-after">2017-08-31</div>
					        </div>
				        </li>
				        <li class="item-content">
					        <div class="item-inner">
					          <div class="item-title">地　点:</div>
					          <div class="item-after">广州市天河区黄埔大道55555号</div>
					        </div>
				        </li>
				    </ul>
				  </div>
			</div>
		</div>
		
		
{include file="Public:footer" /}

<script>
var  page = 1;
 /*** ajax 提交表单 查询订单列表结果*/  
 function ajax_sourch_submit()
 {	 	 	 
	 	$("#all_quan").show();
        page += 1;
		$.ajax({
			type : "GET",
			//url:"/index.php?m=Mobile&c=User&a=collect_list&is_ajax=1&p="+page,//+tab,			
			url:"/Users/allMake/is_ajax/1/p/"+page,//+tab,
//			data : $('#filter_form').serialize(),// 你的formid 搜索表单 序列化提交
			success: function(data)
			{
				$("#all_quan").hide();
				if($.trim(data) == ''){
					$('.all_more').hide();
				}else{
				    $("#all_activity").append(data);
				}
			}
		}); 
 } 
 
 var  page_release = 1;
 /*** ajax 提交表单 查询订单列表结果*/  
 function ajax_sourch_release_submit()
 {	 	 	 
	 	$("#release_quan").show();
        page_release += 1;
		$.ajax({
			type : "GET",
			//url:"/index.php?m=Mobile&c=User&a=collect_list&is_ajax=1&p="+page,//+tab,			
			url:"/Users/release_Make/is_ajax/1/p/"+page_release,//+tab,
//			data : $('#filter_form').serialize(),// 你的formid 搜索表单 序列化提交
			success: function(data)
			{
				$("#release_quan").hide();
				if($.trim(data) == ''){
					$('.release_more').hide();
				}else{
				    $("#release_activity").append(data);
				}
			}
		}); 
 } 
 
 var  page_stay = 1;
 /*** ajax 提交表单 查询订单列表结果*/  
 function ajax_sourch_stay_submit()
 {	 	 	 
	 	$("#stay_quan").show();
	 	page_stay += 1;
		$.ajax({
			type : "GET",
			//url:"/index.php?m=Mobile&c=User&a=collect_list&is_ajax=1&p="+page,//+tab,			
			url:"/Users/pendingAuditMake/is_ajax/1/p/"+page_stay,//+tab,
//			data : $('#filter_form').serialize(),// 你的formid 搜索表单 序列化提交
			success: function(data)
			{
				$("#stay_quan").hide();
				if($.trim(data) == ''){
					$('.stay_more').hide();
				}else{
				    $("#stay_activity").append(data);
				}
			}
		}); 
 } 
 
 var  page_not = 1;
 /*** ajax 提交表单 查询订单列表结果*/  
 function ajax_sourch_not_submit()
 {	 	 	 
	 	$("#not_quan").show();
	 	page_stay += 1;
		$.ajax({
			type : "GET",
			//url:"/index.php?m=Mobile&c=User&a=collect_list&is_ajax=1&p="+page,//+tab,			
			url:"/Users/notPassMake/is_ajax/1/p/"+page_stay,//+tab,
//			data : $('#filter_form').serialize(),// 你的formid 搜索表单 序列化提交
			success: function(data)
			{
				$("#not_quan").hide();
				if($.trim(data) == ''){
					$('.not_more').hide();
				}else{
				    $("#not_activity").append(data);
				}
			}
		}); 
 } 
</script>

		<script>
			Zepto(document).on('click','.open-3-modal', function () {
			    Zepto.modal({
			      title:  '进行中，确定己经参与了本活动吗？',
			      text: '',
			      buttons: [
			        {
			          text: '取消',
			          onClick: function() {
			          }
			        },
			        {
			          text: '确定',
			          color:'danger',
			          onClick: function() {
			          }
			        },
			      ]
			    })
		    });
		</script>
		<style>
			.modal-title{font-size:.75rem;}
			.modal-inner{background:#fff;}
			.modal-button{height:2rem;background:#fff;line-height:2rem;font-size:.625rem;}
			.modal-button:first-child{color:#0894ec;}
			.modal-button:last-child{color:#0894ec;}
		</style>
	</body>

</html>